]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
st-scroll-view: properly check if the scrollbars are visible
authorEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>
Mon, 15 Jul 2013 15:42:43 +0000 (17:42 +0200)
committerEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>
Wed, 17 Jul 2013 15:33:26 +0000 (17:33 +0200)
We don't set :visible on the scrollbars, but use booleans to track
if they are visible. Thus check the booleans instead of the actor's
properties when allocating the scrollbars.

https://bugzilla.gnome.org/show_bug.cgi?id=704265

src/st/st-scroll-view.c

index 9ea394b05a154c7b34bfa5be8d82801a481604d2..04e263f609b67aff04f400236a769eda060bac92 100644 (file)
@@ -598,7 +598,7 @@ st_scroll_view_allocate (ClutterActor          *actor,
    */
 
   /* Vertical scrollbar */
-  if (CLUTTER_ACTOR_IS_VISIBLE (priv->vscroll))
+  if (vscrollbar_visible)
     {
       if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL)
         {
@@ -617,7 +617,7 @@ st_scroll_view_allocate (ClutterActor          *actor,
     }
 
   /* Horizontal scrollbar */
-  if (CLUTTER_ACTOR_IS_VISIBLE (priv->hscroll))
+  if (hscrollbar_visible)
     {
       if (clutter_actor_get_text_direction (actor) == CLUTTER_TEXT_DIRECTION_RTL)
         {